package main

import (
	"fmt"
	"strconv"
	"time"
)

func main() {
	// go 开启一个协程
	// 主线程结束，者协程也结束
	go test()
	/*for i:=0;i<10;i++ {
		fmt.Println("main() hello.world" + strconv.Itoa(i))
		time.Sleep(time.Second)
	}*/
}

func test() {
	for i := 0; i < 10; i++ {
		fmt.Println("hello.world" + strconv.Itoa(i))
		time.Sleep(time.Second)
	}
}
